home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 4: Demo 1 / almathera_demo1.bin / sourcecode / dexion / simple spr.s < prev    next >
Text File  |  1995-03-17  |  2KB  |  99 lines

  1. org $38000
  2. load $38000
  3. j:
  4. jmp amiga
  5. execbase=4
  6. permit=-138
  7. even
  8. gfxname: 
  9. dc.b "graphics.library",0
  10. even 
  11. gfxbase:
  12. dc.l 0
  13. oldc:
  14. dc.l 0
  15. ;
  16. ; openlib
  17. ;
  18. amiga:
  19. move.l execbase,a6
  20. lea gfxname,a1
  21. jsr -408(a6)
  22. move.l d0,gfxbase
  23. clr.l d0
  24.  
  25. ; stopmultitasking
  26. move.l execbase,a6
  27. jsr -132(a6)
  28. move.l gfxbase,a0
  29. add.l #$32,a0
  30. move.w #$0080,$dff096
  31. move.l (a0),oldc
  32. move.l #coplist,(a0)
  33. move.l a0,-(a7)
  34. move.w #$8080,$dff096
  35. move.b #151,d0
  36. move.b #194,d1
  37. move.b #64,d2
  38. move.b #44,d3
  39. move.b #1,d4
  40. move.b #1,d5
  41. ;
  42. ; wait for raster
  43. ;
  44. vloop:
  45. move.w $dff006,d6
  46. and.w #$ff00,d6
  47. cmp.w #$c000,d6
  48. bne vloop
  49. add.b d4,d2
  50. subq.b #1,d0
  51. bne mad
  52. move.b #151,d0
  53. eor.b #$fe,d4
  54. mad:
  55. move.b d2,$25001
  56. add.b d5,d3
  57. subq.b #1,d1
  58. bne sen
  59. move.b #194,d1
  60. eor.b #$fe,d5
  61. sen:
  62. move.b d3,$25000
  63. move.b d3,d6
  64. add.b #6,d6
  65. move.b d6,$25002
  66. bottun:
  67. andi.b #64,$bfe001
  68. bne vloop
  69. move.l (a7)+,a0
  70. move.l oldc,(a0)
  71. rts
  72. coplist:
  73. dc.w $0100,$1200
  74. dc.w $00e0,$0004,$00e2,$0000
  75. dc.w $008e,$2c91,$0090,$41f0
  76. dc.w $0092,$0038,$0094,$00d0
  77. dc.w $0096,$83a0
  78. dc.w $0104,$0024,$0108,$0000,$010a,$0000
  79. ;
  80. dc.w $0180,$0000,$0182,$0fe0,$0184,$030c
  81. dc.w $0186,$050c,$0188,$080d,$018a,$0b0e
  82. dc.w $018c,$0e0e,$018e,$0f0c
  83. dc.w $0190,$06b5,$0192,$0b59,$0194,$0b7a
  84. dc.w $0196,$0c8b,$0198,$0dac,$019a,$0dcd
  85. dc.w $019c,$0eee,$019e,$0000
  86. dc.w $01a2,$0ff0,$01a4,$00ff,$01a6,$0f0f
  87. ; spr pointer
  88. dc.w $0120,$0002,$0122,$5000,$0124,$0003,$0126,$0000
  89. dc.w $0128,$0003,$012a,$0000,$012c,$0003,$012e,$0000
  90. dc.w $0130,$0003,$0132,$0000,$0134,$0003,$0136,$0000
  91. dc.w $0138,$0003,$013a,$0000,$013c,$0003,$013e,$0000
  92. sprite:
  93. org $25000
  94. load $25000
  95. ;spr data
  96. dc.w $6d60,$7200,$ffff,$07e0,$13c8,$0ff0,$23c4,$1ff8
  97. dc.w $13c8,$0ff0,$0990,$07e0,$0000,$0000
  98. dc.w $ffff,$fffe
  99.